<html>

<head>
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
    <title>爱优享</title>
    <meta name="viewport" content="initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="stylesheet" type="text/css" href="${staticpath}/front/dist/css/sm.css">
<#--<link rel="stylesheet" type="text/css" href="${staticpath}/front/dist/css/sm-extend.css">-->
    <link rel="stylesheet" type="text/css" href="${staticpath}/front/dist/css/master.css">
    <link rel="stylesheet" type="text/css" href="${staticpath}/front/dist/css/idangerous.swiper.css">
    <link rel="stylesheet" type="text/css" href="${staticpath}/front/dist/css/base.css">
    <link rel="stylesheet" type="text/css" href="//at.alicdn.com/t/font_c2fouqhk6na5rk9.css">
    <style>
        .offline-item {
            background: #FFFFFF;
            border-bottom: 1px solid #dadada;
            padding: 0 15px;
            padding-bottom: 10px;
        }

        .offline-item h1 {
            font-size: 14px;
            font-weight: normal;
            height: 44px;
            line-height: 44px;
            text-overflow: ellipsis;
        }

        .offline-item p {
            margin: 0;
            margin-top: 5px;
            color: #999;
            overflow: hidden;
            text-overflow: ellipsis;
            font-size: 12px;
        }

        .swiper-slide img {
            width: 100%;
        }

        .red-slide {
            background: #ca4040;
        }

        .blue-slide {
            background: #4390ee;
        }

        .orange-slide {
            background: #ff8604;
        }

        .green-slide {
            background: #49a430;
        }

        .pink-slide {
            background: #973e76;
        }

        .swiper-slide .title {
            font-style: italic;
            font-size: 42px;
            margin-top: 80px;
            margin-bottom: 0;
            line-height: 45px;
        }

        .swiper-pagination {
            position: absolute;
            z-index: 20;
            left: 10px;
            bottom: 10px;
        }

        .swiper-pagination-switch {
            display: inline-block;
            width: 8px;
            height: 8px;
            border-radius: 8px;
            background: #222;
            margin-right: 5px;
            opacity: 0.8;
            border: 1px solid #fff;
            cursor: pointer;
            background: no-repeat;
        }

        .swiper-visible-switch {
            background: #aaa;
        }

        .swiper-active-switch {
            background: #fff;
        }

        /*轮播图 分页居中*/
        .swiper-pagination {
            left: 50% !important;
            transform: translateX(-50%);
            -weibkit-transform: translateX(-50%);
        }

        .modal {
            width: 10rem;
            margin-left: -5rem;
        }

        .modal-inner, .modal-button {
            font-size: 0.65rem;
        }

        .modal-button, .modal-buttons {
            height: 1.75rem;
            line-height: 1.75rem;
        }

    </style>
</head>

<body>
<div class="page-group">
    <div class="page" id="page-infinite-scroll-bottom">
        <!--搜索栏内容 !-->
        <header class="bar bar-nav">
            <h1 class="title">首页</h1>
        </header>
        <div class="content shopping-content infinite-scroll infinite-scroll-bottom" data-distance="100">
            <!-- 幻灯片Slider -->
            <div class="swiper-container">
                <div class="swiper-wrapper">
                </div>
                <div class="swiper-pagination"></div>
            </div>
            <div class="data-center">
                <span>
                    <img src="${staticpath}/images/wallet.png" alt="人数"/>
                    <p>爱心钱包:0元</p>
                </span>
                 <span>
                    <img src="${staticpath}/images/loveIcon.png" alt="人数"/>
                    <p>公益时间:0小时</p>
                     <input type="hidden" class="url" data-vurl="${basepath}/front/account/toAccountEdit"
                            data-ourl="${basepath}/front/account/toOrganizeEdit"/>
                </span>
            </div>
            <!--fn-block!-->
            <div class="fn-block">
                <a href="javascript:;"><i class="iconfont icon-erweima"></i>扫码打卡 <i
                        class="iconfont icon-xiangyou pull-right"></i></a>
                <a class="activity-door" data-vurl="${basepath}/front/account/toAccountOfflineList"
                   data-ourl="${basepath}/front/account/toMyIssue"><i class="iconfont icon-paixingbang"></i>我的活动 <i
                        class="iconfont icon-xiangyou pull-right"></i></a>
            </div>

            <!--信息列表页!-->
            <div class="buttons-tab">
                <a href="#new-tab" class="tab-link active button">资讯</a>
                <a href="#offline-tab" class="tab-link button">活动推荐</a>
            </div>
            <div class="tabs">
                <!--新闻列表页!-->
                <div id="new-tab" class="tab active infinite-scroll">
                </div>
                <div id="offline-tab" class="tab infinite-scroll" data-url="${basepath}/front/offline/toOfflineDetail">
                <#--<div class="offline-item">-->
                        <#--<h1>活动标题</h1>-->
                        <#--<p>活动简介</p>-->
                        <#--<p>2017-08-09</p>-->
                    <#--</div>-->
                </div>
            </div>
            <!-- 加载提示符 -->
            <div class="infinite-scroll-preloader">
                <div class="preloader"></div>
            </div>
        </div>
        <!--工具栏!-->
        <nav class="bar bar-tab" id="tool-bar">
            <a class="tab-item external active" href="#">
                <span class="iconfont icon-shouye"></span>

                <p class="tab-label">首页</p>
            </a>
            <a class=" tab-item love-external" href="${basepath}/front/offline/toOfflineList">
                <span class="iconfont icon-huodong"></span>

                <p class="tab-label">活动</p>
            </a>
            <a class="tab-item external" href="${basepath}/front/catalog/toMallList">
                <span class="iconfont iconfont icon-shangcheng"></span>

                <p class="tab-label">商城</p>
            </a>
            <a class="tab-item external" href="${basepath}/front/account/toAccountList">
                <span class="iconfont icon-wo"></span>

                <p class="tab-label">我</p>
            </a>
        </nav>
    </div>
</div>
<script type='text/javascript' src='${staticpath}/front/dist/js/lib/zepto.js' charset='utf-8'></script>
<script type='text/javascript' src='${staticpath}/front/dist/js/lib/idangerous.swiper.min.js' charset='utf-8'></script>
<script>
    $.config = {
        router: false
    }
    $.ajax({
        type: 'GET',
        dataType: 'json',
        url: '/getSession',
        success: function (data) {
            if (data.data.account != null) {
                sessionStorage.id = data.data.account.id;
//                判断账号状态 未审核 弹窗 提示审核
                if (sessionStorage.count == undefined) {
                    if (data.data.account.status == 3) {
                        $.alert('账号未认证，请先认证')
                        sessionStorage.count = 0;
                    } else if (data.data.account.status == 2) {
                        $.alert('账号认证失败，请重新认证')
                        sessionStorage.count = 0;
                    }
                }
                sessionStorage.role = 0;
                var str = JSON.stringify(data.data);
                sessionStorage.obj = str;
            } else {
                if (sessionStorage.count == undefined) {
                    if (data.data.organize.status == 3) {
                        $.alert('账号未认证，请先认证')
                        sessionStorage.count = 0;
                    } else if (data.data.organize.status == 2) {
                        $.alert('账号认证失败，请重新认证')
                        sessionStorage.count = 0;
                    }
                }
                sessionStorage.id = data.data.organize.id;
                sessionStorage.role = 1;
                var str = JSON.stringify(data.data);
                sessionStorage.obj = str;
            }
        }
    })

</script>

<script type='text/javascript' src='${staticpath}/front/dist/js/lib/sm.js' charset='utf-8'></script>
<#--<script type='text/javascript' src='${staticpath}/front/dist/js/lib/sm-extend.js' charset='utf-8'></script>-->

<script type='text/javascript' src="${staticpath}/front/dist/js/home.js"></script>
<script>
    $.init();
</script>
</body>

</html>
